package com.example.apptodo;

import java.io.Serializable;

import android.content.ContentValues;

public class Todo implements Serializable {

	private static final long serialVersionUID = 1L;
	private long id;
	private String action;
	private int year;
	private int month;
	private int day;
	private int hour;
	private int minute;
	
	public long getId() {
		return id;
	}
	public String getAction() {
		return action;
	}
	public void setId(long id) {
		this.id = id;
	}
	public void setAction(String action) {
		this.action = action;
	}
	public int getYear() {
		return year;
	}
	public int getMonth() {
		return month;
	}
	public int getDay() {
		return day;
	}
	public int getHour() {
		return hour;
	}
	public int getMinute() {
		return minute;
	}
	public void setYear(int year) {
		this.year = year;
	}
	public void setMonth(int month) {
		this.month = month;
	}
	public void setDay(int day) {
		this.day = day;
	}
	public void setHour(int hour) {
		this.hour = hour;
	}
	public void setMinute(int minute) {
		this.minute = minute;
	}
	/**
	 * オブジェクトの内容をContentValuesの型に変換する
	 * @return	ContentValuesオブジェクト
	 */
	public ContentValues toContentValues() {
		ContentValues cv = new ContentValues();
		cv.put("action", this.action);
		cv.put("year", this.year);
		cv.put("month", this.month);
		cv.put("day", this.day);
		cv.put("hour", this.hour);
		cv.put("minute", this.minute);
		return cv;
	}
}
